#ifndef RECOMMEND_H
#define RECOMMEND_H

#include <iostream>
#include <assert.h>
#include <map>
#include <memory>
#include <boost/range/algorithm.hpp>
#include "../interface/AllInterface.h"
#include "../recall/UserCLRecall.h"
#include "../recall/UserLabelRecall.h"
#include "../rank/RoughSort.h"
#include "../rank/FineSort.h"
#include "../rank/AfterSort.h"
using namespace std;


class RecommendImpl :public RecommendInterface {
public:
	RecommendImpl();
	~RecommendImpl();
	virtual void init() override;
	virtual vector<ItemUtil::Item*>* recommend(shared_ptr<Request> rp, void *p) override ;
private:
	UserInfo* userinfo_;
	map<string,RecallInterface*>  recalls_;
	SortInterface* rs_;
	SortInterface* fs_;
	SortInterface* as_;
};

class RecommendFactory {
public:
	RecommendFactory(const int value) ;
	RecommendInterface* getRecommendSys(const int i) ;
	vector<RecommendInterface*> pl_ ;
};


#endif // !RECOMMEND_H
